From: Sebastian Keller Date: Wed, 24 Feb 2021 22:22:52 +0000 (+0100) Subject: windowPreview: Unset selected if window was clicked to switch workspaces X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~616^2^2~225 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=a6588d054f4c4536174443736b37bb627b5e14e8;p=gnome-shell.git windowPreview: Unset selected if window was clicked to switch workspaces This is used to detect whether a click was short enough to select a window and activate it or long enough to start a drag. Usually when clicking on a window and selecting it, this leaves the overview, but when clicking on a window on a neighboring workspace, the overview is kept open, but selected is not unset in this case. So all attempts at dragging the window after using it to switch workspaces will fail. Fixes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3783 Part-of: --- diff --git a/js/ui/windowPreview.js b/js/ui/windowPreview.js index a27d0586f..bb97ebc63 100644 --- a/js/ui/windowPreview.js +++ b/js/ui/windowPreview.js @@ -819,8 +819,10 @@ var WindowPreview = GObject.registerClass({ // run - make sure to not start a drag in that case this._longPressLater = Meta.later_add(Meta.LaterType.BEFORE_REDRAW, () => { delete this._longPressLater; - if (this._selected) + if (this._selected) { + this._selected = false; return; + } let [x, y] = action.get_coords(); action.release(); this._draggable.startDrag(x, y, global.get_current_time(), this._dragTouchSequence, event.get_device());